package com.neusoft.service;

import com.neusoft.mapper.CourseMapper;
import com.neusoft.po.Course;
import com.neusoft.po.ResponseBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CourseServiceImpl implements CourseService{
    @Autowired
    private CourseMapper cm;

    @Override
    public ResponseBean<Course> getCourseByNo(String cno) {
        Course course = cm.getCourseByNo(cno);
        ResponseBean<Course> rb = new ResponseBean<>(course);
        rb.setMsg("11000"); // 为了区别是哪个服务响应的请求
        return rb;
    }
}
